// es2016：

// 1. Array.prototype.includes(): 数组查询
// TypedArray.prototype.inclues()
// es5中使用indexOf()查询元素:有返回数组下标，没有返回-1
const arr = [1, 2, 3, 'sdasdsad', NaN]
console.log(arr.indexOf(1)); //0
console.log(arr.indexOf('s')); //-1
console.log(arr.indexOf(NaN)); //-1
// indexOf无法查询NaN数据

console.log(arr.includes(1)); //true
console.log(arr.includes(NaN)); //true

const uint8 = new Uint8Array([1, 2, 3, NaN])
console.log(uint8);
console.log(uint8.includes(1)); //true
console.log(uint8.includes(3, 2)); //true
console.log(uint8.includes(NaN)); //false
console.log(new Float32Array([NaN]).includes(NaN)); //TRUE


// 2. 指数运算符   **

console.log(Math.pow(2, 10)); //1024
console.log(2 ** 10); //1024